HEX
Server: Apache/2.4.52 (Ubuntu)
System: Linux WebLive 5.15.0-79-generic #86-Ubuntu SMP Mon Jul 10 16:07:21 UTC 2023 x86_64
User: ubuntu (1000)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/html/wpicare/wp-content/plugins/tracking-code-manager/includes/classes/utils/Cron.php
<?php
if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

class TCMP_Cron {
	public function __construct() {

	}
	public function init() {
		add_filter( 'cron_schedules', array( $this, 'add_schedules' ) );
		add_action( 'wp', array( $this, 'schedule_Events' ) );
	}
	public function add_schedules( $schedules = array() ) {
		global $tcmp;
		// Adds once weekly to the existing schedules.
		$schedules['weekly'] = array(
			'interval' => 604800,
			'display'  => $tcmp->lang->L( 'Once Weekly' ),
		);

		return $schedules;
	}
	public function schedule_Events() {
		$this->weekly_events();
		$this->daily_events();
	}
	private function weekly_events() {
		if ( ! wp_next_scheduled( 'tcmp_weekly_scheduled_events' ) ) {
			wp_schedule_event( current_time( 'timestamp' ), 'weekly', 'tcmp_weekly_scheduled_events' );
		}
	}
	private function daily_events() {
		if ( ! wp_next_scheduled( 'tcmp_daily_scheduled_events' ) ) {
			wp_schedule_event( current_time( 'timestamp' ), 'daily', 'tcmp_daily_scheduled_events' );
		}
	}
}